And document the existing ones.
</variablelist>
The special value <literal>all</literal> can be used to turn on all
- debug options.
+ debug options. The special value <literal>help</literal> can be used
+ to obtain a list of all supported debug options.
</para>
</formalpara>
</para>
</formalpara>
+<formalpara>
+ <title><envar>GDK_GL</envar></title>
+
+ <para>
+ This variable can be set to a list of options that influence various aspects
+ of the OpenGL support in GTK+.
+ <variablelist>
+ <varlistentry>
+ <term>disable</term>
+ <listitem><para>Disable OpenGL support</para></listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>always</term>
+ <listitem><para>Always use OpenGL for rendering</para></listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>software-draw</term>
+ <listitem><para>Use software rendering</para></listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>texture-rectangle</term>
+ <listitem><para>Use the texture rectangle extension</para></listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>legacy</term>
+ <listitem><para>Use a legacy OpenGL context</para></listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>gles</term>
+ <listitem><para>Use a GLES context</para></listitem>
+ </varlistentry>
+ </variablelist>
+ The special value <literal>all</literal> can be used to turn on all
+ options. The special value <literal>help</literal> can be used
+ to obtain a list of all supported options.
+ </para>
+</formalpara>
+
<formalpara>
<title><envar>GTK_CSD</envar></title>
static const GDebugKey gdk_gl_keys[] = {
{ "disable", GDK_GL_DISABLE },
{ "always", GDK_GL_ALWAYS },
- { "software-draw", GDK_GL_SOFTWARE_DRAW_GL | GDK_GL_SOFTWARE_DRAW_SURFACE} ,
- { "software-draw-gl", GDK_GL_SOFTWARE_DRAW_GL },
- { "software-draw-surface", GDK_GL_SOFTWARE_DRAW_SURFACE },
+ { "software-draw", GDK_GL_SOFTWARE_DRAW } ,
{ "texture-rectangle", GDK_GL_TEXTURE_RECTANGLE },
{ "legacy", GDK_GL_LEGACY },
{ "gles", GDK_GL_GLES },
guint target;
paint_context = gdk_gl_context_get_current ();
- if ((_gdk_gl_flags & GDK_GL_SOFTWARE_DRAW_SURFACE) == 0 &&
+ if ((_gdk_gl_flags & GDK_GL_SOFTWARE_DRAW) == 0 &&
paint_context &&
GDK_GL_CONTEXT_GET_CLASS (paint_context)->texture_from_surface &&
GDK_GL_CONTEXT_GET_CLASS (paint_context)->texture_from_surface (paint_context, surface, region))
typedef enum {
GDK_GL_DISABLE = 1 << 0,
GDK_GL_ALWAYS = 1 << 1,
- GDK_GL_SOFTWARE_DRAW_GL = 1 << 2,
- GDK_GL_SOFTWARE_DRAW_SURFACE = 1 << 3,
- GDK_GL_TEXTURE_RECTANGLE = 1 << 4,
- GDK_GL_LEGACY = 1 << 5,
- GDK_GL_GLES = 1 << 6
+ GDK_GL_SOFTWARE_DRAW = 1 << 2,
+ GDK_GL_TEXTURE_RECTANGLE = 1 << 3,
+ GDK_GL_LEGACY = 1 << 4,
+ GDK_GL_GLES = 1 << 5
} GdkGLFlags;
typedef enum {
GtkWidget *gl_box;
GtkWidget *gl_combo;
GtkWidget *software_gl_switch;
- GtkWidget *software_surface_switch;
GtkWidget *texture_rectangle_switch;
GtkAdjustment *focus_adjustment;
_("Not settable at runtime.\nUse GDK_GL=always or GDK_GL=disable instead"));
gtk_switch_set_active (GTK_SWITCH (vis->priv->software_gl_switch),
- flags & GDK_GL_SOFTWARE_DRAW_GL);
- gtk_switch_set_active (GTK_SWITCH (vis->priv->software_surface_switch),
- flags & GDK_GL_SOFTWARE_DRAW_SURFACE);
+ flags & GDK_GL_SOFTWARE_DRAW);
gtk_switch_set_active (GTK_SWITCH (vis->priv->texture_rectangle_switch),
flags & GDK_GL_TEXTURE_RECTANGLE);
if (flags & GDK_GL_DISABLE)
{
gtk_widget_set_sensitive (vis->priv->software_gl_switch, FALSE);
- gtk_widget_set_sensitive (vis->priv->software_surface_switch, FALSE);
gtk_widget_set_sensitive (vis->priv->texture_rectangle_switch, FALSE);
gtk_widget_set_tooltip_text (vis->priv->software_gl_switch, _("GL rendering is disabled"));
- gtk_widget_set_tooltip_text (vis->priv->software_surface_switch, _("GL rendering is disabled"));
gtk_widget_set_tooltip_text (vis->priv->texture_rectangle_switch, _("GL rendering is disabled"));
}
}
static void
software_gl_activate (GtkSwitch *sw)
{
- update_gl_flag (sw, GDK_GL_SOFTWARE_DRAW_GL);
-}
-
-static void
-software_surface_activate (GtkSwitch *sw)
-{
- update_gl_flag (sw, GDK_GL_SOFTWARE_DRAW_SURFACE);
+ update_gl_flag (sw, GDK_GL_SOFTWARE_DRAW);
}
static void
gtk_widget_class_bind_template_child_private (widget_class, GtkInspectorVisual, gl_box);
gtk_widget_class_bind_template_child_private (widget_class, GtkInspectorVisual, gl_combo);
gtk_widget_class_bind_template_child_private (widget_class, GtkInspectorVisual, software_gl_switch);
- gtk_widget_class_bind_template_child_private (widget_class, GtkInspectorVisual, software_surface_switch);
gtk_widget_class_bind_template_child_private (widget_class, GtkInspectorVisual, texture_rectangle_switch);
gtk_widget_class_bind_template_child_private (widget_class, GtkInspectorVisual, font_scale_entry);
gtk_widget_class_bind_template_child_private (widget_class, GtkInspectorVisual, font_scale_adjustment);
gtk_widget_class_bind_template_callback (widget_class, layout_activate);
gtk_widget_class_bind_template_callback (widget_class, widget_resize_activate);
gtk_widget_class_bind_template_callback (widget_class, software_gl_activate);
- gtk_widget_class_bind_template_callback (widget_class, software_surface_activate);
gtk_widget_class_bind_template_callback (widget_class, texture_rectangle_activate);
}
</child>
</object>
</child>
- <child>
- <object class="GtkListBoxRow">
- <property name="visible">True</property>
- <property name="activatable">False</property>
- <child>
- <object class="GtkBox">
- <property name="visible">True</property>
- <property name="orientation">horizontal</property>
- <property name="margin">10</property>
- <property name="spacing">40</property>
- <child>
- <object class="GtkLabel" id="software_surface_label">
- <property name="visible">True</property>
- <property name="label" translatable="yes">Software Surfaces</property>
- <property name="halign">start</property>
- <property name="valign">baseline</property>
- <property name="xalign">0.0</property>
- </object>
- </child>
- <child>
- <object class="GtkSwitch" id="software_surface_switch">
- <property name="visible">True</property>
- <property name="halign">end</property>
- <property name="valign">baseline</property>
- <property name="hexpand">1</property>
- <signal name="notify::active" handler="software_surface_activate"/>
- </object>
- </child>
- </object>
- </child>
- </object>
- </child>
<child>
<object class="GtkListBoxRow">
<property name="visible">True</property>
<widget name="touchscreen_label"/>
<widget name="gl_label"/>
<widget name="software_gl_label"/>
- <widget name="software_surface_label"/>
<widget name="texture_rectangle_label"/>
</widgets>
</object>